import Vue from "vue";
import Vuex from "vuex";
import page from "./modules/page";
import label from "./modules/label";
import language from "./modules/language";

Vue.use(Vuex);
// 设置页数
// pageNum 当前页
// pageSize 当前页条目数
// pageTotal 所有页面的条目数

const store = new Vuex.Store({
  state: {
    isDev: process.env.NODE_ENV === "development",
    qtApi: null
  },
  actions: {
    setQtApi({ state }, value) {
      state.qtApi = value;
    }
  },
  modules: {
    page,
    label,
    language
  }
});
export default store;
